﻿//using System;
//using System.IO;
//using System.Runtime.Serialization.Json;
//using Petra.Gis.Support;

//namespace Petra.Gis
//{
//  public class Configuration
//  {

//    ////not creatable outside of this assembly
//    //internal Configuration()
//    //{ }


//    ////not inheritable
//    //protected abstract void seal()
//    //{ }




//    public Configuration()
//    {
//      Settings = new GisSettings();
//      Components = new CustomComponents();
//    }





//    //must load first 
//    //private static GisSettings _settings;

//    public GisSettings Settings
//    { get; private set; }






//    //load as second
//    public CustomComponents Components
//    { get; private set; }







//    //private void _load()
//    //{
//    //  string pathJson = Environment.GetSystemPath();

//    //  if (pathJson == null)
//    //    return;

//    //  FileStream fsj = new FileStream(pathJson, FileMode.Open, FileAccess.Read);
//    //  DataContractJsonSerializer outp = new DataContractJsonSerializer(typeof(ConfigurationPersistables));

//    //  ConfigurationPersistables tmp = (ConfigurationPersistables)outp.ReadObject(fsj);

//    //  this.Settings = tmp.Settings;
//    //  this.Components = tmp.Components;

//    //  fsj.Close();
//    //}

//  }
//}
